//
//  SpatialSearchIndicatorViewController.m
//  dataGathering
//
//  Created by macmini on 15/3/24.
//  Copyright (c) 2015年 shuili. All rights reserved.
//

#import "SpatialSearchIndicatorViewController.h"

@interface SpatialSearchIndicatorViewController ()

@end

@implementation SpatialSearchIndicatorViewController
@synthesize titleLabel;
@synthesize subtitleLabel;
@synthesize detailedLabel;

- (void)viewDidLoad {
    [super viewDidLoad];
    switch (_searchType) {
        case 0:
            _titleString = @"矩形拉框查询";
            _subtitleString = @"在地图上画出矩形，查询矩形范围内的要素";
            _detailedString = @"请在地图上点选划出矩形进行查询";
            break;
        case 1:
            _titleString = @"多边形拉框查询";
            _subtitleString = @"在地图上画出多边形，查询多边形范围内的要素";
            _detailedString = @"请在地图上选划出多边形进行查询";
            break;
        case 2:
            _titleString = @"手绘面查询";
            _subtitleString = @"在地图上进行手绘，查询手绘范围内的要素";
            _detailedString = @"请在地图上手绘出范围进行查询";
            break;
        case 3:
            _titleString = @"线查询";
            _subtitleString = @"在地图上画出直线，查询直线范围内的要素";
            _detailedString = @"请在地图上选划出直线进行查询";
            break;
        case 4:
            _titleString = @"缓冲区查询";
            _subtitleString = @"在地图上画出原型区域，查询圆型范围内的要素";
            _detailedString = @"请在地图上点选划出圆形进行查询";
            break;
            
        default:
            break;
    }
    [titleLabel setText:_titleString];
    [subtitleLabel setText:_subtitleString];
    [detailedLabel setText:_detailedString];
}
- (IBAction)backButtonClicked:(id)sender {
    [((UINavigationController*)(self.parentViewController)) popViewControllerAnimated:YES];
    [[NSNotificationCenter defaultCenter] postNotificationName:@"exitSpatialSearchMode" object:nil];
}

-(void)backToParentView
{
    [((UINavigationController*)(self.parentViewController)) popViewControllerAnimated:NO];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
